<!DOCTYPE html>
<html>
<body style="margin: 0; padding: 0;">
<div style="width: 300px; height: 100px;">
  <script>
    function log_focused() {
      let log = document.getElementById("focused_log");
      log.innerText = "Focused";
    }
  </script>
  <button style="margin: 25px; border: 0; width: 250px; height: 50px" onfocus="log_focused()">
    Button with focus handler
  </button>
  <div id="focused_log"></div>
</div>
</body>
</html>
